<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<%@ include file="/WEB-INF/views/include/constrant.jsp"%>
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>我的订单</title>
<script src="${ctxStatic }/jquery/jquery-1.8.3.min.js"></script>
<link rel="stylesheet" href="${ctxStatic }/gov/css/govmyoder.css" />
<link rel="stylesheet" href="${ctxStatic }/gov/css/gov_total.css" />

<link href="${ctxStatic }/xiake/css/list.css" rel='stylesheet' type='text/css' />
<script>
$(document).ready(function() {
	if("${message}".length>0){
		alert("${message}");
	}
})

function submitForm(){
    var form = document.getElementById("my_form");//获取form表单对象
    form.submit();//form表单提交
}
function page(n,s){
	$("#pageNo").val(n);
	$("#pageSize").val(s);
	$("#my_form").submit();
	return false;
}
	</script>
</head>
<body>
		 <%@include file="../index/head.jsp" %>
	<div id="gov_order">
			<div class="gov_main">
				<div class="table_box">
					<table cellpadding="0" cellspacing="0">
						<tr class="order_tbox">
							<th>订单名称</th>
							<th>出发日期</th>
							<th>总金额</th>
							<th>
							<form id="my_form" method="post" action="${ctxGov}/orderList">
							<input id="pageNo" name="pageNo" type="hidden" value="1"/>
							<input id="pageSize" name="pageSize" type="hidden" value="6"/>
								<select  onchange="submitForm();" id="orderstatus" name="orderstatus">
									<option selected="selected" value="">订单状态</option>
									<option value="0">已支付</option>
									<option value="1">未支付</option>
									<option value="2">已退单</option>
									<option value="9">已取消</option>
								</select>
							</form>
							</th>
							<th>操作</th>
						</tr>
						
						<c:forEach items="${page.list}" var="info">
						<tr class="tit_o">
							<td colspan="5">
								<div class="tito_cc">
									<span class="date_le">订单号码：${info.orderid}</span>
									<span class="time_ri">订单日期：<fmt:formatDate value="${info.createDate}" pattern="yyyy-MM-dd hh:mm" /></span>
								</div>
							</td>
						</tr>
						<tr class="order_f">
							<td>
								${info.ordername}
							</td>
							<td>
								<fmt:formatDate value="${info.departdate}" pattern="yyyy-MM-dd" />
							</td>
							<td>${info.dueamount}</td>
							<c:if test="${info.orderstatus == '0'}">
							<td>已支付</td>
							<td class="to_paym">
								<span><a href="${ctxGov}/orderBack?orderid=${info.orderid}">退单</a></span>
								<span><a href="${ctxGov}/checkOrder?orderid=${info.orderid}" target="_blank	">查看</a></span>
							</td>
							</c:if>
							<c:if test="${info.orderstatus == '1'}">
							<td>未支付</td>
							<td class="no_paym">
								<span><a href="${ctxGov}/payOrder?orderid=${info.orderid}">支付</a></span>
								<span><a href="${ctxGov}/cancelOrder?orderid=${info.orderid}">取消</a></span>
								<span><a href="${ctxGov}/checkOrder?orderid=${info.orderid}" target="_blank	">查看</a></span>
							</td>
							</c:if>
							<c:if test="${info.orderstatus == '9'}">
							<td>已取消</td>
							<td class="to_void">
								<span><a href="${ctxGov}/checkOrder?orderid=${info.orderid}" target="_blank	">查看</a></span>
							</td>
							</c:if>
							<c:if test="${info.orderstatus == '2'}">
							<td>已退单</td>
							<td class="to_void">
								<span><a href="${ctxGov}/checkOrder?orderid=${info.orderid}" target="_blank	">查看</a></span>
							</td>
							</c:if>
						</tr>
						</c:forEach>
					</table>
				</div>
			</div>
			<div style="text-align: center;">
		<div class="pagination  font_normal_size" >${page.html}</div></div>
		</div>
		 <%@include file="../index/foot.jsp" %>
	</body>
 </html>